<#include "/layout/layout.ftl">
<#import "/layout/macro.ftl" as macro>
<#import "/layout/select.ftl" as my/>
<#assign css>
<#--此ftl中用到的css-->
    <style>
        .col-sm-9{
            padding-top:7px;
        }
        .form-label-this{
            padding-top:0 !important;
            background-color: #f9f9f9;
            /*margin-left:5px;*/
        }
        .form-horizontal .form-group{
            margin-left:0 !important;
            margin-right:0 !important;
        }
        /*.form-input-this{
            border-bottom: 1px solid #aaaaaa;
        }*/
    </style>
</#assign>
<#assign js>
<#--此ftl中用到的js-->
    <script>
    </script>
</#assign>
<@layout title="详情" active="order">
    <!-- Content Header (Page header) -->
    <section class="content-header">
        <h1>
            <small>订单详细信息</small>
        </h1>
        <ol class="breadcrumb">
            <li><a href="/"><i class="fa fa-home"></i> 管理后台</a></li>
            <li><a href="#"><i class="fa fa-list-ul"></i> 订单管理</a></li>
            <li class="active"><i class="fa fa-edit"></i>详细信息</li>
        </ol>
    </section>
    <!-- Main content -->
    <section class="content">
    <div class="row">
    <div class="col-md-12">
    <!-- Default box -->
    <div class="box  box-primary">
    <form class="form-horizontal form-edit" method="post" action="">
    <#if order.type ==1>
        <div class="box-body">
        <table class="table table-striped">
        <tr>
            <th>序号</th>
            <th>分站ID</th>
            <th>订单号</th>
            <th>订单类型</th>
            <th>订单子类型</th>
            <th>发单时间</th>
            <th>取消时间</th>
            <th>取消类型</th>
            <th>总金额</th>
            <th>支付类型</th>
            <th>收货验证码</th>
        </tr>
        <tr>
        <td >${order.id!}</td>
        <td >${order.agentId!}</td>
        <td >${order.orderNo!}</td>
        <td >
        <#if order.type??>
            ${convert('SERVICE_CLASS',order.type) !}
        </#if>
        </td>
        <td >
        <#if order.type??>
            <#if order.childType??>
                ${convert('SERVICE_CLASS',order.type,order.childType) !}
            </#if>
        </#if>
        </td>
        <td >${(order.taskTime?string('yyyy-MM-dd HH:mm:ss'))!}</td>
            <td >${(order.cancleTime?string('yyyy-MM-dd HH:mm:ss'))!}</td>
            <td >
                <#if order.cancleBy??>
                    <#if order.cancleBy == 1 >
                        系统取消
                    </#if>
                    <#if order.cancleBy == 2 >
                        用户取消
                    </#if>
                </#if>
            </td>
        <td >${order.amount?string('0.00')!}</td>
        <td >${convert('PAY_TYPE',order.payType) !}</td>
        <td >${order.verifyCode!}</td>
        </tr>
        </table>

    <br/> <br/>
    <input type="hidden" id="id" name="id" value="${order.id!}">
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">接单师傅：</label><div class="col-sm-3 form-input-this">
    <#if master??>
        ${master.masterName!}
        </#if>
    </div>
    <label class="col-sm-3 control-label form-label-this">接单时间：</label><div class="col-sm-3 form-input-this">${(accitity.createDt?string('yyyy-MM-dd HH:mm:ss'))!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">师傅电话：</label><div class="col-sm-3 form-input-this">${masterPhone!}</div>
    <label class="col-sm-3 control-label form-label-this">到达起点：</label><div class="col-sm-3 form-input-this">${(order.originTime?string('yyyy-MM-dd HH:mm:ss'))!}&#160;&#160;${operatorOrigin!}</div>
        </div>

            <div class="form-group">
                <label class="col-sm-3 control-label form-label-this">下单人电话：</label><div class="col-sm-3 form-input-this">${userPhone!}</div>
            </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">起点：</label><div class="col-sm-3">
                <#if fromAddress??>
                    ${fromAddress.title!}
                    ${fromAddress.detail!}
                    &#160;&#160;
                    ${fromAddress.name!}
                    &#160;&#160;
                    ${fromAddress.phone!}
                </#if>
            </div>
    <label class="col-sm-3 control-label form-label-this">到达终点：</label><div class="col-sm-3 form-input-this">${(order.finalTime?string('yyyy-MM-dd HH:mm:ss'))!}&#160;&#160;${operatorFinal!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">终点：</label><div class="col-sm-3 form-input-this">
                <#if toAddress??>
                    ${toAddress.title!}
                    ${toAddress.detail!}
                    &#160;&#160;
                    ${toAddress.name!}
                    &#160;&#160;
                    ${toAddress.phone!}
                </#if>
            </div>
    <label class="col-sm-3 control-label form-label-this">完成订单：</label><div class="col-sm-3 form-input-this">${(finishTime?string('yyyy-MM-dd HH:mm:ss'))!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">临时加价：</label><div class="col-sm-3 form-input-this">${order.otherFee!} &#160;${order.nightFee!}</div>
    <label class="col-sm-3 control-label form-label-this">完成方式：</label><div class="col-sm-3 form-input-this">${finishStatus!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">距离（公里）：</label><div class="col-sm-3 form-input-this">${order.distance!}</div>
    <label class="col-sm-3 control-label form-label-this">取消时间：</label><div class="col-sm-3 form-input-this">${(order.cancleTime?string('yyyy-MM-dd HH:mm:ss'))!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">重量：</label><div class="col-sm-3 form-input-this">${order.weight!}</div>
    <label class="col-sm-3 control-label form-label-this">优惠券：</label><div class="col-sm-3 form-input-this">${order.couponId!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">备注信息：</label><div class="col-sm-3 form-input-this">${order.remark!}</div>
    <label class="col-sm-3 control-label form-label-this">物品图片：</label>
        <div class="col-sm-3 form-input-this">
        <#if images??>
            <#list images as item>
                <img src="${item!}" style="with:100px;" />&#160;
            </#list>
        </#if>
        </div>
        </div>

            <div class="form-group">
                <label class="col-sm-3 control-label form-label-this">师傅拍照</label>
                <div class="col-sm-3 form-input-this">
                    <#if goodsImages??>
                        <#list goodsImages as item>
                            <img src="${item!}" style="width:200px;" />&#160;
                            <br/>
                        </#list>
                    </#if>
                </div>
            </div>



    <#-- <div class="form-group"><label class="col-sm-3 control-label">总金额：</label><div class="col-sm-9">${order.amount!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">备注：</label><div class="col-sm-9">${order.remark!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">订单类型：</label><div class="col-sm-9">${convert('SERVICE_CLASS',order.type)!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">子类型：</label><div class="col-sm-9">
         <#if order.type??>
             <#if order.childType??>
                 ${convert('SERVICE_CLASS',order.type,order.childType) !}
             </#if>
         </#if>
     </div></div>
     <div class="form-group"><label class="col-sm-3 control-label">订单状态：</label><div class="col-sm-9">${convert('DATA_STATUS',order.status)!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">取货地址：</label><div class="col-sm-9">${order.fromAddressId!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">送货地址：</label><div class="col-sm-9">${order.toAddressId!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">更新时间：</label><div class="col-sm-9">${(order.updateAt?string('yyyy-MM-dd HH:mm:ss'))!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">创建时间：</label><div class="col-sm-9">${(order.createAt?string('yyyy-MM-dd HH:mm:ss'))!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">支付时间：</label><div class="col-sm-9">${(order.payAt?string('yyyy-MM-dd HH:mm:ss'))!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">用户id：</label><div class="col-sm-9">${order.userId!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">删除状态：</label><div class="col-sm-9">${convert('DATA_STATUS',order.deleteState)!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">取货送货时间：</label><div class="col-sm-9">${(order.taskTime?string('yyyy-MM-dd HH:mm:ss'))!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">类型id：</label><div class="col-sm-9">${order.categoryId!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">类型名称：</label><div class="col-sm-9">${order.categoryName!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">重量(公斤)：</label><div class="col-sm-9">${order.weight!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">代收款：</label><div class="col-sm-9">${order.collectionAmount!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">代收款手续费：</label><div class="col-sm-9">${order.collectionFee!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">服务费：</label><div class="col-sm-9">${order.serviceFee!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">保价金额：</label><div class="col-sm-9">${order.insurance!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">保价手续费：</label><div class="col-sm-9">${order.insuranceFee!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">保价赔付金额：</label><div class="col-sm-9">${order.insurancePayment!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">验证码：</label><div class="col-sm-9">${order.verifyCode!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">距离(公里)：</label><div class="col-sm-9">${order.distance!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">优惠券id：</label><div class="col-sm-9">${order.couponId!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">其他费用(如特殊天气)：</label><div class="col-sm-9">${order.otherFee!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">其他费用说明：</label><div class="col-sm-9">${order.otherFeeInstruction!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">支付类型：</label><div class="col-sm-9">${convert('PAY_TYPE',order.payType)!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">预计送达时间：</label><div class="col-sm-9">${(order.forecastDeliveryTime?string('yyyy-MM-dd HH:mm:ss'))!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">实际送达时间：</label><div class="col-sm-9">${order.deliveryTime!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">商品费用（随意购时生效）：</label><div class="col-sm-9">${order.goodsAmount!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">万能帮办图片：</label><div class="col-sm-9">${order.images!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">师傅id：</label><div class="col-sm-9">${order.masterId!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">分站id：</label><div class="col-sm-9">${order.agentId!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">深夜服务费：</label><div class="col-sm-9">${order.nightFee!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">订单唯一码：</label><div class="col-sm-9">${order.outTradeNo!}</div></div>
     <div class="form-group"><label class="col-sm-3 control-label">支付流水号：</label><div class="col-sm-9">${order.transNo!}</div></div>-->
        </div>
    <#else>
        <div class="box-body">
        <table class="table table-striped">
        <tr>
            <th>序号</th>
            <th>分站ID</th>
            <th>订单号</th>
            <th>订单类型</th>
            <th>订单子类型</th>
            <th>发单时间</th>
            <th>取消时间</th>
            <th>取消类型</th>
            <th>总金额</th>
            <th>支付类型</th>
        </tr>
        <tr>
        <td >${order.id!}</td>
        <td >${order.agentId!}</td>
        <td >${order.orderNo!}</td>
        <td >
        <#if order.type??>
            ${convert('SERVICE_CLASS',order.type) !}
        </#if>
        </td>
        <td >
        <#if order.type??>
            <#if order.childType??>
                ${convert('SERVICE_CLASS',order.type,order.childType) !}
            </#if>
        </#if>
        </td>
        <td >${(order.taskTime?string('yyyy-MM-dd HH:mm:ss'))!}</td>
            <td >${(order.cancleTime?string('yyyy-MM-dd HH:mm:ss'))!}</td>
            <td >
                <#if order.cancleBy??>
                    <#if order.cancleBy == 1 >
                        系统取消
                    </#if>
                    <#if order.cancleBy == 2 >
                        用户取消
                    </#if>
                </#if>
            </td>
        <td >${order.amount?string('0.00')!}</td>
        <td >${convert('PAY_TYPE',order.payType) !}</td>
        </tr>
        </table>

    <br/> <br/>
    <input type="hidden" id="id" name="id" value="${order.id!}">
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">接单师傅：</label><div class="col-sm-3 form-input-this"><#if master??>${master.masterName!}</#if></div>
    <label class="col-sm-3 control-label form-label-this">接单时间：</label><div class="col-sm-3 form-input-this">${(accitity.createDt?string('yyyy-MM-dd HH:mm:ss'))!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">师傅电话：</label><div class="col-sm-3 form-input-this">${masterPhone!}</div>
    <label class="col-sm-3 control-label form-label-this">到达服务地址：</label><div class="col-sm-3 form-input-this">${(order.originTime?string('yyyy-MM-dd HH:mm:ss'))!}</div>
        </div>
            <div class="form-group">
                <label class="col-sm-3 control-label form-label-this">下单人电话：</label><div class="col-sm-3 form-input-this">${userPhone!}</div>
            </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">服务地址：</label><div class="col-sm-3">${toAddress.title!} ${toAddress.detail!}&#160;&#160;${toAddress.name!}&#160;&#160;${toAddress.phone!}</div>
    <label class="col-sm-3 control-label form-label-this">服务计时：</label><div class="col-sm-3 form-input-this">${serverTimes!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">优惠券：</label><div class="col-sm-3 form-input-this">${order.couponId!}</div>
    <label class="col-sm-3 control-label form-label-this">完成订单：</label><div class="col-sm-3 form-input-this">${(finishTime?string('yyyy-MM-dd HH:mm:ss'))!}</div>
        </div>
        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">备注信息：</label><div class="col-sm-3 form-input-this">${order.remark!}</div>
    <label class="col-sm-3 control-label form-label-this">取消时间：</label><div class="col-sm-3 form-input-this">${(order.cancleTime?string('yyyy-MM-dd HH:mm:ss'))!}</div>
        </div>

        <div class="form-group">
    <label class="col-sm-3 control-label form-label-this">师傅拍照</label>
            <div class="col-sm-3 form-input-this">
                <#if goodsImages??>
                    <#list goodsImages as item>
                        <img src="${item!}" style="width:200px;" />&#160;
                        <br/>
                    </#list>
                </#if>
            </div>
    <label class="col-sm-3 control-label form-label-this">图片：</label>
        <div class="col-sm-3 form-input-this">
        <#if images??>
            <#list images as item>
                <img src="${item!}" style="width:200px;" />&#160;
                <br/>
            </#list>
        </#if>
        </div>
        </div>
        </div>
    </#if>

    <div class="box-footer">
        <button type="button" class="btn btn-default btn-back">返回</button>
    </div>

    </form>
    </div>
    <!-- /.box -->
    </div>
    </div>
    </section>
    <!-- /.content -->
</@layout>
